if(!requestScreenCapture()){
    toast("请求截图失败");
    exit();
}
sleep(1000);
// click(497,1450)
// sleep(4000)
log("开始截图");



log("by:"+1)
var img = captureScreen()
log("by:"+2)
sleep(200)
let x1 = 72
let y1 = 1666
let x2 = 373
let y2 = 1769
var imgClip = images.clip(img,x1,y1,x2-x1,y2-y1)//291,801
images.save(imgClip,"/sdcard/wifiauto/wifi2.png")
img.recycle()


/*
let armMe = images.read("/sdcard/wifiauto/wifi991.png")
let armMeAll = captureScreen()
let result = findImage(armMeAll,armMe,{
    // region:[840,805,1067-840,2268-805],
    threshold:0.95
});
 
if(result){
    log("has")
    log(result.x)
    log(result.y)
    click(result.x+50,result.y+50)
}else{
    log("wu")
};
*/
